package com.cupk.dtos;

import lombok.Data;
import jakarta.validation.constraints.Size;
import jakarta.validation.constraints.DecimalMin;
import jakarta.validation.constraints.Min;
import java.math.BigDecimal;
import java.time.LocalDate;
import java.util.List;

/**
 * 更新成果请求DTO
 */
@Data
public class UpdatePublicationRequest {
    
    @Size(max = 200, message = "成果标题不能超过200个字符")
    private String title;
    
    private String type; // JOURNAL, CONFERENCE, PATENT, SOFTWARE, BOOK, OTHER
    
    private String status; // DRAFT, SUBMITTED, UNDER_REVIEW, ACCEPTED, PUBLISHED, REJECTED
    
    @Size(max = 500, message = "作者信息不能超过500个字符")
    private String authors;
    
    @Size(max = 200, message = "期刊/会议名称不能超过200个字符")
    private String journal;
    
    @Size(max = 2000, message = "摘要不能超过2000个字符")
    private String abstractText;
    
    @Size(max = 500, message = "关键词不能超过500个字符")
    private String keywords;
    
    private LocalDate publishDate;
    
    @Size(max = 100, message = "DOI不能超过100个字符")
    private String doi;
    
    @Size(max = 500, message = "URL不能超过500个字符")
    private String url;
    
    @DecimalMin(value = "0.0", message = "影响因子不能为负数")
    private BigDecimal impactFactor;
    
    @Min(value = 0, message = "引用次数不能为负数")
    private Integer citationCount;
    
    private Long projectId;

    private String documentUrl;

    private String documentName;

    private List<String> attachments;
}
